/*
 *  Report.cpp
 *  Report
 *
 *  Created by Hamza SHAWY on 20/10/07.
 *  Copyright 2007 __MyCompanyName__. All rights reserved.
 *
 */

#include "Report.h"
#include "Reference.h"

 #include <iostream>
 #include <iomanip>
 
 using std::cout;
 using std::endl;



/* Definition of the default constructor  "Report" of the class "Report" */ 
    Report::Report( ) : Reference ( -1 , -1, "<undefined yet>" , "<undefined yet>"), 
    Department ("< undefined yet >"), Institution(" <undefined yet> ")
	{} // end Report default constructor

/* Definition of the regular constructor  "Report"  */     
	Report::Report(int id, int year, string author, string title, string inst, string dep ) : Reference ( id, year, author, title),
	Institution (inst), Department (dep)
	{}// end Report regular constructor
															  
/*  Definition of the dedstructor  "~Report" of the class "Report"  */ 
    Report::~Report()    
	{} // end Report destructor	 

/*  Definition of the method "getDepartment" of the class "Report"  */    
    string Report::getDepartment() const
	  {
        return Department ; // returns the department
	  } // end function getDepartment
	  
/*  Definition of the method "getInstitution" of the class "Report"  */    
    string Report::getInstitution() const
	  {
        return Institution ; // returns the institution
	  } // end function getInstitution
	  			  	  	  
	  
/*  Definition of the method "print" of the class "Report"	*/																																																																								  
	void Report::print() const  //prints a string representation of this report consisting of the departmentand the institution concerned 
	  {
        Reference :: print(); //  This member function overrides the one defined in the class Reference.
		cout << "         * The Report is also specified by its : "<< endl;
		cout <<  "						5) Department which is : "<< getDepartment()<<endl;
		cout <<  "						6) Institution which is : "<< getInstitution()<<endl;
	  } // end function print	 

	
/*  Definition of the member function "setIdentifier" of the class "Report" */     
    void Report::setDepartment( string dep  )  // Sets the report's department                
    {                                                           
       Department = dep ;                     
	} // end function setDepartment

/* Definition of the member function "setInstitution" of the class "Report" */     
    void Report::setInstitution( string inst )  // Sets the report's insttution                  
    {                                                           
       Institution = inst ;                     
	} // end function setInstitution 

/* Definition of the member function "setNumberOfPages" of the class "Report" */     
    void Report::setNumberOfPages(int numb)  // Sets the report's number of pages                  
    {                                                           
       NumberOfPages = numb ;                     
	} // end function setNumbeerOfPages 	
